import { Mock, Constant } from './_utils'

const { ApiPrefix } = Constant

// 
const Indicators = Mock.mock({
    NewProject: { title: "新建工程", total:  735, civicism: 3675, connection: 48 },
    Finished: {  title: "完成设计", total:  1236, civicism: 43, connection: 6, length: 418 },
    Contract: { title: "合同签订", total:  89, civicism: 43, connection: 6 },
    Acceptance: { title: "竣工验收", total:  735, civicism: 43, connection: 6, length: 10 },
    civicism: {
        title: "市政工程",
        total: 6,
        build:  1,      // 新建
        building: 3,    // 在建
        built: 2        // 完成
    },
    connection: { title: "接水工程", total: 6, build:  1, building: 3, built: 2 },
})

const Analysis = Mock.mock({
  gdjj: { title: "管道基建", val: 9.09 },
  lxgw: { title: "零星管网", val: 1.02 },
  szgb: { title: "市政挂表", val: 9.09 },
  ecgc: { title: "二次工程", val: 1.02 },
  sbcg: { title: "水表采购", val: 9.09 },
})

module.exports = {
  [`POST ${ApiPrefix}/project/getIndicators`](req, res) {
    res.send({
        info: "查询成功",
        status: 0,
        data: Indicators
    });
  },
  [`POST ${ApiPrefix}/project/getAnalysis`](req, res){
    res.send({
        info: '查询成功',
        status: 0,
        data: Analysis
    });
  },
}
